﻿using System;
using Autodesk.Revit.DB;

namespace YJKRevitPreview
{
	public struct TextNoteInfo
	{
		public TextNoteInfo(TextNoteInfo rhs)
		{
			this.m_Text = rhs.m_Text;
			this.m_Color = rhs.m_Color;
			this.m_Height = rhs.m_Height;
			this.m_Position = rhs.m_Position;
			this.m_AlignH = rhs.m_AlignH;
			this.m_AlignV = rhs.m_AlignV;
			this.m_BoundingBoxWidth = rhs.m_BoundingBoxWidth;
			this.m_BoundingBoxHeight = rhs.m_BoundingBoxHeight;
			this.m_Angle = rhs.m_Angle;
		}

		public TextNoteInfo(string text, PenColor color, double height, XYZ center, double boundingBoxWidth, double boundingBoxHeight)
		{
			this.m_Text = text;
			this.m_Color = color;
			this.m_Height = height;
			this.m_Position = center;
			this.m_AlignH = TextNoteInfo.AlignHType.AHT_Center;
			this.m_AlignV = TextNoteInfo.AlignVType.AVT_Middle;
			this.m_BoundingBoxWidth = boundingBoxWidth;
			this.m_BoundingBoxHeight = boundingBoxHeight;
			this.m_Angle = 0.0;
		}

		public TextNoteInfo(string text, PenColor color, double height, XYZ pos, TextNoteInfo.AlignHType alignHType, TextNoteInfo.AlignVType alignVType, double boundingBoxWidth, double boundingBoxHeight)
		{
			this.m_Text = text;
			this.m_Color = color;
			this.m_Height = height;
			this.m_Position = pos;
			this.m_AlignH = alignHType;
			this.m_AlignV = alignVType;
			this.m_BoundingBoxWidth = boundingBoxWidth;
			this.m_BoundingBoxHeight = boundingBoxHeight;
			this.m_Angle = 0.0;
		}

		public TextNoteInfo(string text, PenColor color, double height, XYZ center, double boundingBoxWidth, double boundingBoxHeight, double angle)
		{
			this.m_Text = text;
			this.m_Color = color;
			this.m_Height = height;
			this.m_Position = center;
			this.m_AlignH = TextNoteInfo.AlignHType.AHT_Center;
			this.m_AlignV = TextNoteInfo.AlignVType.AVT_Middle;
			this.m_BoundingBoxWidth = boundingBoxWidth;
			this.m_BoundingBoxHeight = boundingBoxHeight;
			this.m_Angle = angle;
		}

		public TextNoteInfo(string text, PenColor color, double height, XYZ pos, TextNoteInfo.AlignHType alignHType, TextNoteInfo.AlignVType alignVType, double boundingBoxWidth, double boundingBoxHeight, double angle)
		{
			this.m_Text = text;
			this.m_Color = color;
			this.m_Height = height;
			this.m_Position = pos;
			this.m_AlignH = alignHType;
			this.m_AlignV = alignVType;
			this.m_BoundingBoxWidth = boundingBoxWidth;
			this.m_BoundingBoxHeight = boundingBoxHeight;
			this.m_Angle = angle;
		}

		public string m_Text;

		public PenColor m_Color;

		public double m_Height;

		public XYZ m_Position;

		public TextNoteInfo.AlignHType m_AlignH;

		public TextNoteInfo.AlignVType m_AlignV;

		public double m_BoundingBoxWidth;

		public double m_BoundingBoxHeight;

		public double m_Angle;

		public enum AlignHType
		{
			AHT_Left,
			AHT_Center,
			AHT_Right
		}

		public enum AlignVType
		{
			AVT_Top,
			AVT_Middle,
			AVT_Bottom
		}
	}
}
